<template>
  <div id="app">
    <NavTop class="navtop" />
    <router-view></router-view>
    <div class="lookNum"><AsnLookNum :num="lookNum"></AsnLookNum></div>
    <Footer />
  </div>
</template>

<script>
import NavTop from "./components/comcomponents/NavTop";
import Footer from "./components/comcomponents/Footer";
import { getAsyncToken } from "@/api/wechat";
import { getAsyncList } from "@/api/ipApi";

export default {
  name: "App",
  components: {
    NavTop,
    Footer,
  },
  data() {
    return {
      lookNum: 0,
    };
  },
  methods: {
    async getLookNum() {
      try {
        const { data } = await getAsyncList();
        this.lookNum = data;
      } catch (err) {}
    },
  },
  created() {
    this.getLookNum();
  },
};
</script>

<style lang="less">
#app {
  font-family: "Avenir", Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-align: center;
  color: #2c3e50;
  width: 100%;
  .navtop {
    position: fixed;
    z-index: 1000;
    width: 100%;
  }

  .lookNum {
    position: fixed;
    z-index: 9999;
    bottom: 20px;
    left: 10px;
  }
}
</style>
